{extend name="main/index" /}
{block name="main"}


<div class="content-page" style="margin-top:50px;">
    <table class="table table-hover table-striped" style="background-color:#fff;">
        <tr>
            <th width="5%">Id</th>
            <th width="15%">用户名</th>
            <th width="15%">真实姓名</th>
            <th width="20%">所属角色</th>
            <th>Option</th>
        </tr>
        {volist name="list" id="v"}
        <tr>
            <td><strong>{$v.id}</strong></td>
            <td>{$v.username}</td>
            <td>{$v.name}</td>
            <td>
                {volist name="v.role" id="role"}
                <span style="color:#999">{$role.name}</span>
                {/volist}
            </td>
            <td>
                <a href="{:url('admin/User/rolelist', ['id' => $v.id])}" class="btn btn-info">分配角色</a>
                <button href="{:url('admin/User/edit', ['id' => $v.id])}" class="btn btn-info">编辑</button>
                <button class="btn btn-danger">删除</button>
            </td>
        </tr>
        {/volist}
    </table>
</div>

{/block}